package com.th.service.impl;

import com.th.bean.Employye;
import com.th.mapper.EmployyeMapper;
import com.th.service.EmployyeService;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import javax.annotation.Resource;
import java.util.List;
@Service
@Transactional
public class EmployyeServiceImpl implements EmployyeService {
    @Resource
    private EmployyeMapper employyeMapper;
    @Override
    public List<Employye> findAll() {
        return employyeMapper.findAll();
    }

    @Override
    public int delete(Integer id) {
        return employyeMapper.delete(id);
    }

    @Override
    public int insert(Employye employye) {
        return employyeMapper.insert(employye);
    }

    @Override
    public int update(Employye employye) {
        return employyeMapper.update(employye);
    }
}
